function __init__pubmed()
    DEPNAME = "PubMed"
    LINK = "https://github.com/kimiyoung/planetoid/raw/master/data"
    DOCS = "https://github.com/kimiyoung/planetoid"
    DATA = "ind.pubmed." .* ["x", "y", "tx", "allx", "ty", "ally", "graph", "test.index"]

    register(DataDep(DEPNAME,
                     """
                     Dataset: The $DEPNAME dataset.
                     Website: $DOCS
                     """,
                     map(x -> "$LINK/$x", DATA),
                     "0b8bf8e80564611b540655e9cbb8c5900dd3728d4ababe0b990b6f27144bd76c"  # if checksum omitted, will be generated by DataDeps
                     # post_fetch_method = unpack
                     ))
end

"""
    PubMed(; dir=nothing, reverse_edges=true)

The PubMed citation network dataset from Ref. [1].
Nodes represent documents and edges represent citation links.
The dataset is designed for the node classification task. 
The task is to predict the category of certain paper.
The dataset is retrieved from Ref. [2].

# References

[1]: [Deep Gaussian Embedding of Graphs: Unsupervised Inductive Learning via Ranking](https://arxiv.org/abs/1707.03815)

[2]: [Planetoid](https://github.com/kimiyoung/planetoid)
"""
struct PubMed <: AbstractDataset
    metadata::Dict{String, Any}
    graphs::Vector{Graph}
end

function PubMed(; dir = nothing, reverse_edges = true)
    metadata, g = read_planetoid_data("PubMed", dir = dir, reverse_edges = reverse_edges)
    return PubMed(metadata, [g])
end

Base.length(d::PubMed) = length(d.graphs)
Base.getindex(d::PubMed, ::Colon) = d.graphs[1]
Base.getindex(d::PubMed, i) = getindex(d.graphs, i)

# DEPRECATED in v0.6.0
function Base.getproperty(::Type{PubMed}, s::Symbol)
    if s === :dataset
        @warn "PubMed.dataset() is deprecated, use `PubMed()` instead."
        function dataset(; dir = nothing)
            d = PubMed(; dir)
            g = d[1]
            adjacency_list = edgeindex2adjlist(g.edge_index..., g.num_nodes)
            return (; g.num_nodes, g.num_edges,
                    node_features = g.node_data.features,
                    node_labels = g.node_data.targets,
                    train_indices = mask2indexes(g.node_data.train_mask),
                    val_indices = mask2indexes(g.node_data.val_mask),
                    test_indices = mask2indexes(g.node_data.test_mask),
                    adjacency_list)
        end
        return dataset
    else
        return getfield(PubMed, s)
    end
end
